<div
	style="min-height: 300px; padding-bottom: 20px; width: 50%; float: left"
	class="portlet x12">
<div class="portlet-header">
<h4>
Album ảnh
<div class="buttonrow" style="float: right; margin-right: 20px;"><a
	href="<?php
	echo base_url ();
	?>admin/gallery/addalbum"><input type="button"
	value="Thêm mới album" class="btn btn-orange"></a></div>
</div>
</h4>
<!-- .portlet-header -->
<div class="portlet-content">
<table cellpadding="0" cellspacing="0" align="center"
	style="width: 100%;">
	<tr>
		<td style="width: 100%;">
		<table cellpadding="0" cellspacing="0" align="center"
			style="width: 100%;">
			<thead>
				<tr>
					<th>Tên</th>
					<th style="width: 20%;">Chức năng</th>
				</tr>
			</thead>
	<?php
	if (count ( $list ) > 0) {
	?>
	<?php
		foreach ( $list as $item ) {
			?>
		<tr>
			<td><a href="<?php echo base_url();?>admin/gallery/listphotos/<?php echo $item->id; ?>">
				<span style="font-size:14px;"><?php	echo $item->name;	?></span></a>
			</td>
			<td style="width: 20%;">
				<input type="button" value="Xoá" class="btn btn-red" onclick="del_item('<?php	echo $item->id;	?>')">
			</td>
		</tr>
	<?php
		}
		?>
	<?php
	} else {
		?>
		<tr class="fontGL row0">
			<td colspan="3"><span style="font-size: 13px;">Không có Album</span></td>
		</tr>
	<?php
	}
	?>

		</table>
		</td>
	</tr>
	<tr><td>&nbsp;</td></tr>

</table>


</div>

</div>
<!--END main-->
<script>



function del_item(id,type){

	var store_del = confirm("Xoa hinh anh ?");

	if(store_del==true){
		window.location="<?php echo base_url();?>admin/gallery/deltheme/"+id;
	}else{
		return false;
	}
}
function edit_info(id){
	document.location.href="<?php
	echo base_url ();
	?>admin/gallery/edit_theme/"+id;
}
</script>